<template>
  <div class="radioYuan" v-for="(value, index) in props.list" :key="index" @click="handleClickBtn(value.val)">
    <div class="topRadio">{{ value.val }}</div>
    <div class="radioText">
      <span> {{ value.text }}</span>
      <span> {{ value.mbit }}</span>
    </div>
  </div>
</template>
<script setup>
import { defineProps, onMounted, defineEmits  } from "vue";

const props = defineProps({
  list: {
    type: Array,
  },
});

const emits = defineEmits(['handleClickBtn'])

const handleClickBtn = (val) => {
  emits('handleClickBtn', val)
}

onMounted(() => {});
</script>
<style lang='less' scoped>
.radioYuan {
  // width: 20%;
  width: 22%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  .topRadio {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d6e3ea;
    font-size: 16px;
    width: 75%;
    height: 60%;
    background-image: url("../assets/iconBorder/yuanhuan.png");
    background-repeat: no-repeat;
    background-size: 100% 100%;
    margin: 0 auto;
  }
  .radioText {
    color: #9da4b1;
    font-size: 14px;
    width: 100%;
    height: 30%;
    text-align: center;
    span {
      display: block;
    }
  }
}
</style>
